/*

* ------------------------------------------------------------------------
* ------------------------------------------------------------------------
* |     Smart-Shop开源商城系统/ Java商城-首选电商平台系统 请务必保留此注释头信息
* |     开源地址: https://gitee.com/ningbo-qishan/gruul-mall
* ------------------------------------------------------------------------
* ------------------------------------------------------------------------
* |     可正常分享和学习源码,未经授权 不可商用！
* |     商业版中台购买/开源版商业授权 联系技术客服
* |     官网:  https://www.73app.cn/
* ------------------------------------------------------------------------
* ------------------------------------------------------------------------
* |     Copyright (c) 2016-2999 宁波启山智软科技有限公司
* |     版权所有 ,侵权必究！
* ------------------------------------------------------------------------

*/
package com.medusa.gruul.finance.api.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.medusa.gruul.common.data.base.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * <p>
 * 订单设置
 * </p>
 *
 * @author alan
 * @since 2020 -03-09
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("t_finance_order_setting")
@ApiModel(value = "FinanceOrderSetting对象", description = "订单设置")
public class FinanceOrderSetting extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @NotNull
    @ApiModelProperty(value = "id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 商铺ID
     */
    @ApiModelProperty(value = "商铺ID")
    @TableField("shop_id")
    private String shopId;

    /**
     * 申请售后时间（日）
     */
    @NotNull(message = "申请售后时间不能为空")
    @Min(value = 1, message = "申请售后时间不能小于1")
    @ApiModelProperty(value = "申请售后时间（日）")
    @TableField("support_allowed_day")
    private Integer supportAllowedDay;

    /**
     * 售后审核时间（日）
     */
    @NotNull(message = "售后审核时间不能为空")
    @Min(value = 1, message = "售后审核时间不能小于1")
    @ApiModelProperty(value = "售后审核时间（日）")
    @TableField("support_audit_day")
    private Integer supportAuditDay;

    /**
     * 快递AppId
     */
    @ApiModelProperty(value = "快递AppId")
    @TableField("kd_app_id")
    private String kdAppId;

    /**
     * 快递AppKey
     */
    @ApiModelProperty(value = "快递AppKey")
    @TableField("kd_app_key")
    private String kdAppKey;

    /**
     * 支付方式
     */
    @NotNull(message = "支付方式不能为空")
    @ApiModelProperty(value = "支付方式：1->微信支付;2->余额支付;3->好友代付;")
    @TableField("payment_model")
    private String paymentModel;

    /**
     * 自定义表单
     */
    @ApiModelProperty(value = "自定义表单")
    @TableField("custom_from")
    private String customFrom;

    /**
     * 积分抵扣比例百分比
     */
    @NotNull(message = "抵扣比例不能为空")
    @Min(value = 0, message = "抵扣比例不能小于0")
    @ApiModelProperty(value = "积分抵扣比例百分比")
    @TableField("ratio")
    private BigDecimal ratio;

    /**
     * 顶底抵扣上限额度百分比
     */
    @NotNull(message = "上限额度不能为空")
    @Min(value = 0, message = "上限额度不能小于0")
    @ApiModelProperty(value = "顶底抵扣上限额度百分比")
    @TableField("ceiling")
    private BigDecimal ceiling;

    /**
     * 是否开启下单通知：0->关闭；1->开启
     */
    @NotNull(message = "是否开启下单通知不能为空")
    @ApiModelProperty(value = "是否开启下单通知：0->关闭；1->开启")
    @TableField("order_notify")
    private Boolean orderNotify;


}
